package edu.nf.service.impl;



import edu.nf.beans.annotations.Component;
import edu.nf.beans.annotations.Inject;
import edu.nf.dao.FindCompleteEmpInfoByIdDao;
import edu.nf.exception.QueryException;
import edu.nf.service.FindCompleteEmpByIdService;

import java.util.Map;

@Component("findCompleteEmpByIdService")
public class FindCompleteEmpByIdServiceImpl implements FindCompleteEmpByIdService {

    @Inject(beanName = "findCompleteEmpInfoByIdDao")
    private FindCompleteEmpInfoByIdDao dao;

    @Override
    public Map<String, Object> findCompleteEmpByEmpid(String empid) {
        try{
            return dao.findCompleteEmpInfoById(empid);
        }catch (Exception e){
            throw new QueryException("find Complete Emp infomation fail");
        }
    }
}
